import request from "..";

export const getTableData = (listName: string,data:any) => {
  return request.post({
    url: `/${listName}/list`,
    data
  })
}
export const removeTableData = (listName:string,id: number) => {
  return request.delete({
    url:`/${listName}/${id}`
  })
}
export const createTableData = (listName: string, data: any) => {
  return request.post({
    url: `/${listName}`,
    data
  })
}
export const editeTableData = (listName: string,id:number,data: any) => {
  return request.patch({
    url: `/${listName}/${id}`,
    data
  })
}